package testcase;

import static org.testng.Assert.assertEquals;

import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;

import base.BaseDriver;
import pages.LoginPage;
import pages.MainPage;
import pages.SportPage;

public class SportPageTest extends BaseDriver{
	LoginPage login_page;
	MainPage main_page;
	SportPage sport_page;
	@BeforeMethod
	public void init() throws InterruptedException {
		login_page=new LoginPage(driver);
		main_page=login_page.loginSuccess("wangyahui","123456");
		sport_page=main_page.click_sport();
	}
	@Test
	public void testClickSportItem() throws InterruptedException {
		sport_page.click_sportItem(3);
		assertEquals(driver.currentActivity(), ".Activity.ExerciseActivity");
	}

}
